<template>
	<view>
		<view class="flash">
			<swiper class="swiper" circular :indicator-dots="true" :autoplay="true" :interval="6000"
				:duration="1000">
				<swiper-item>
					<view class="swiper-item uni-bg-red">A</view>
				</swiper-item>
				<swiper-item>
					<view class="swiper-item uni-bg-green">B</view>
				</swiper-item>
				<swiper-item>
					<view class="swiper-item uni-bg-blue">C</view>
				</swiper-item>
			</swiper>
		</view>
		<view class="program layout">
			<view class="program-column">
				<view class="program-item" @click="handleChapterButton()">
						<view class="program-item-icon">
							<image src="../../../static/logo.png"></image>
						</view>
						<view class="program-item-text">章节练习</view>	
				</view>			
				<view class="program-item">
						<view class="program-item-icon">
							<image src="../../../static/logo.png"></image>
						</view>
						<view class="program-item-text">50篇必考</view>	
				</view>			
				<view class="program-item" @click="handleRandomButton()">
						<view class="program-item-icon">
							<image src="../../../static/logo.png"></image>
						</view>
						<view class="program-item-text">随机练习</view>		
				</view>		
				<view class="program-item">
						<view class="program-item-icon">
							<image src="../../../static/logo.png"></image>
						</view>
						<view class="program-item-text">答题技巧</view>		
				</view>		
			</view>
			<view class="program-content">
				<view class="program-block" @click="handleQuestionButton()">
					<view class="program-block-green">
						<view class="program-block-tooltip">顺序练习</view>
						<view class="program-block-volume">27/2543</view>					
					</view>
				</view>
				<view class="program-block" @click="handlePaperButton()">
					<view class="program-block-blue">
						<view class="program-block-tooltip">模拟考试</view>
						<view class="program-block-volume">去考试</view>		
					</view>
				</view>				
			</view>
			<view class="program-sidebar">
				<view class="program-item" @click="handleMistakesButton()">
					<view class="program-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="program-item-text">我的易错</view>		
				</view>	
				<view class="program-item" @click="handlePaperButton()">
					<view class="program-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="program-item-text">考场模拟</view>		
				</view>					
				<view class="program-item" @click="handleCollectionButton()">
					<view class="program-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="program-item-text">收藏</view>	
				</view>			
				<view class="program-item" @click="handleAnswerCardButton()">
					<view class="program-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="program-item-text">答题卡</view>	
				</view>			
			</view>
		</view>
		<view class="board">
			<view class="board-header">4步轻松学</view>
			<view class="board-box layout">
				<view class="board-box-item">
					<view class="board-box-item-text">第一步</view>
					<view class="board-box-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="board-box-item-tooltip">考点精华科</view>
					<view class="board-box-item-note">仅需3小时</view>
				</view>
				<view class="board-box-item">
					<view class="board-box-item-text">第二步</view>
					<view class="board-box-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="board-box-item-tooltip">精选500题</view>
					<view class="board-box-item-note">高频考点</view>
				</view>
				<view class="board-box-item">
					<view class="board-box-item-text">第三步</view>
					<view class="board-box-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="board-box-item-tooltip">真实考场</view>
					<view class="board-box-item-note">1:1高度还原</view>
				</view>
				<view class="board-box-item">
					<view class="board-box-item-text">第四步</view>
					<view class="board-box-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="board-box-item-tooltip">考前密卷</view>
					<view class="board-box-item-note">快速提分</view>
				</view>
			</view>
			<view class="board-button">马上去学</view>
		</view>
		<view class="process">
			<view class="layout">	
				<view class="process-item">
					<view class="process-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="process-item-text">考试标准</view>
				</view>
				<view class="process-item">
					<view class="process-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="process-item-text">如何约考</view>
				</view>
				<view class="process-item">
					<view class="process-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="process-item-text">如何查成绩</view>
				</view>
				<view class="process-item">
					<view class="process-item-icon">
						<image src="../../../static/logo.png"></image>
					</view>
					<view class="process-item-text">分享成绩单</view>
				</view>
			</view>
		</view>
		<view v-if="1 > 2">
			<view>刷题广场</view>
			<view>
				<view>
					<view>
						<image src="../../../static/logo.png"></image>
					</view>
					<view>
						<view>萱姐</view>
						<view>最近上课听到大家说扣分提很那几，其实答题都是有小技巧的哦</view>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			}
		},
		methods: {
			handleChapterButton:function(){
				uni.redirectTo({
					url:"/pages/examine/chapter/chapter"
				})
			},
			handleRandomButton:function(){
				uni.redirectTo({
					url:"/pages/examine/question/question?questionType=3"
				})
			},
			handleQuestionButton:function(){
				uni.redirectTo({
					url:"/pages/examine/question/question?questionType=2"
				})
			},
			handleMistakesButton:function(){
				uni.redirectTo({
					url:"/pages/examine/mistakes/mistakes"
				})
			},
			handleCollectionButton:function(){
				uni.switchTab({
					url:"/pages/home/home/home"
				})
			},
			handleAnswerCardButton:function(){
				uni.redirectTo({
					url:"/pages/examine/card/card"
				})
			},
			handlePaperButton:function(){
				uni.redirectTo({
					url:"/pages/examine/question/question?questionType=1"
				})
			}
		}
	}
</script>

<style>
.flash { height: 400rpx; background: #ededed; }
.swiper {
	height: 400rpx;
}
.swiper-item {
	display: block;
	height: 400rpx;
	line-height: 400rpx;
	text-align: center;
}

.program { height: 500rpx; padding-top: 30rpx; }
.program-column { width:200rpx; }
.program-sidebar { width:200rpx; }
.program-content { width: 300rpx; }
.program-block { width: 240rpx; height: 200rpx; margin: 0 auto; text-align: center; color: #fff; border-radius: 200rpx; margin-bottom: 50rpx; }
.program-block-green { background: #29d889; padding-top: 50rpx; height: 150rpx;  border-radius: 100%;}
.program-block-blue { background: #71a7ff; padding-top: 50rpx; height: 150rpx;  border-radius: 100%; }

.program-item { width: 100rpx; margin: 0 auto; margin-bottom: 35rpx;}
.program-item-text { font-size: 12px; text-align: center; padding-top: 15rpx; }
.program-item-icon { width: 50rpx; height: 40rpx; margin: 0 auto; }

.board { height: 500rpx; background: #ffefe5; }
.board-header { padding: 30rpx 25rpx; font-size: 20px; font-weight: 800; }
.board-box { padding: 0 25rpx; height: 250rpx; }
.board-box-item { background: #fff; width: 180rpx; margin-right:15rpx; border-radius: 15rpx; padding: 15rpx; font-size: 12px; }
.board-box-item { position: relative; padding-top: 60rpx; }
.board-box-item-text { position: absolute; top: 0; left: 0; background: #fd7112; color: #fff; padding: 10rpx; }
.board-box-item-text { border-top-left-radius: 15rpx; border-bottom-right-radius: 15rpx; font-size: 10px; }
.board-box-item-icon { width: 30rpx; height: 30rpx; margin: 0 auto; padding: 15rpx 0; }
.board-box-item-tooltip { font-size: 14px; font-weight: 700; height:30rpx; overflow: hidden; }
.board-box-item-note { font-size: 12px; padding: 15rpx 0; padding-top: 30rpx; }
.board-button { text-align: center; background: #fed36a; width: 700rpx; margin: 0 auto; color: #370e12; }
.board-button { border-radius: 25rpx; margin-top: 30rpx; padding: 20rpx 0; font-weight: bold; }

.process { height: 200rpx; padding: 25rpx; background: #ededed; }
.process-item { width: 160rpx; height: 200rpx; background: #f5fff7; border: #fff 1px solid; margin: 0 10rpx; border-radius: 15rpx; }
.process-item-icon { width: 60rpx; height: 50rpx; margin: 0 auto; padding-top: 50rpx; margin-bottom: 30rpx;}
.process-item-text { font-size: 14px; text-align: center; font-weight: bold; }
</style>
